home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC World 2007 January
/
PCWorld_2007-01_cd.bin
/
v cisle
/
autoit
/
autoit-v3.2.0.1-setup.exe
/
Examples
/
Helpfile
/
_IEImgGetCollection.au3
< prev
next >
Wrap
Text File
|
2006-07-14
|
1KB
|
29 lines
; *******************************************************
; Example 1 - Create browser at AutoIt homepage, get a reference to
; the 6th Image on the page (note: the first image is index 0)
; and display information about it
; *******************************************************
;
#include <IE.au3>
$oIE = _IECreate ("http://www.autoitscript.com/")
$oImg = _IEImgGetCollection ($oIE, 5)
$sInfo = "Src: " & $oImg.src & @CR
$sInfo &= "FileName: " & $oImg.nameProp & @CR
$sInfo &= "Height: " & $oImg.height & @CR
$sInfo &= "Width: " & $oImg.width & @CR
$sInfo &= "Border: " & $oImg.border
MsgBox(0, "4th Image Info", $sInfo)
; *******************************************************
; Example 2 - Create browser at AutoIt homepage, get Img collection
; and display src URL for each
; *******************************************************
;
#include <IE.au3>
$oIE = _IECreate ("http://www.autoitscript.com/")
$oImgs = _IEImgGetCollection ($oIE)
$iNumImg = @extended
MsgBox(0, "Img Info", "There are " & $iNumImg & " images on the page")
For $oImg In $oImgs
MsgBox(0, "Img Info", "src=" & $oImg.src)
Next